<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html>
<%
	HttpSession se = request.getSession();
	if(se.getAttribute("loginUser") == null){
		request.getRequestDispatcher("/login").forward(request, response);
	}
%>
<html>
<head>
	<meta charset="UTF-8">
	<title>组织管理</title>
	<meta name="viewport"
		content="width=device-width, initial-scale=1, maximum-scale=1">
	<link rel="stylesheet" href="${projectPath}/layui/css/layui.css" media="all">
	<link rel="stylesheet" href="${projectPath}/css/util/jquery.orgchart.css?v=${cache}" media="all">
</head>
<style>
.father_btns {
	width: 40px;
	position: absolute;
	z-index: 999999;
	left: 0px;
	top: 0px;
}
.left_btns{
	margin-bottom: 5px;
}
.gstar_block {
	display: none;
}
.oname_text{
    font-size: 15px;
    white-space: nowrap;
    color: #17b30d;
    font-weight: bold;
}
.refresh_dt {
	z-index: 250;
	position: relative;
	background: white;
	width: 25px;
	display: none;
}
.refresh_dt:hover {
	cursor: pointer;
}
.BMap_cpyCtrl, .anchorBL{
	display: none!important;
}
.tangram-suggestion-main{
	z-index: 2147483647;
}
</style>
<script type="text/javascript">
	var lastOid = "${loginUser.lastOid}"
</script>

<body>
	<script type="text/javascript" src="http://api.map.baidu.com/api?v=3.0&ak=LCbxpXbYqL4sRn5YdcnujSgzhfOr1clr"></script>
	<script src="${projectPath}/js/util/html2canvas.min.js"></script>
	<script src="${projectPath}/js/util/jquery.orgchart.js"></script>
	<script src="${projectPath}/js/sys/organization.js?v=${cache}"></script>
	<script src="${projectPath}/js/sys/organization_map.js?v=${cache}"></script>
	<script src="${projectPath}/js/util/my.js?v=${cache}"></script>
	<blockquote class="layui-elem-quote" style="color: #a7a5a5;padding: 5px;">
		<i class="layui-icon layui-icon-location" style="color: #c5b225;"></i>
		组织管理
	</blockquote>
	<div style="padding:20px 30px;text-align: center;">
		<div id="test1"></div>
	</div>
	<div class="father_btns gstar_block">
		<div class="oname_text"></div>
		<div class="left_btns">
			<button class="layui-btn layui-btn-xs" id="add_Organiztion" style="background-color: #637477;"
				title="添加组织">
				<i class="layui-icon">&#xe61d;</i>
			</button>
		</div>
		<div class="left_btns">
			<button class="layui-btn layui-btn-xs" id="add_project"
				title="添加项目">
				<i class="layui-icon">&#xe624;</i>
			</button>
		</div>
		<div class="left_btns">
			<button class="layui-btn layui-btn-xs layui-btn-warm" id="edit_rganiztion"
				title="编辑">
				<i class="layui-icon">&#xe642;</i>
			</button>
		</div>
		<div class="left_btns">
			<button class="layui-btn layui-btn-xs layui-btn-danger" id="del_Organiztion"
				title="删除">
				<i class="layui-icon">&#xe640;</i>
			</button>
		</div>
	</div>
	<form class="layui-form" action="" id="addOrg_form" lay-filter="addOrg_form" style="display: none;padding:10px;">
		<br>
		<div class="layui-form-item">
			<label class="layui-form-label">组织名称</label>
			<div class="layui-input-inline" style="width: 78%;">
				<input type="text" name="oname" class="layui-input" placeholder="请输入名称">
				<input type="text" name="oid" class="layui-input" style="display: none;">
				<input type="text" name="fid" class="layui-input" style="display: none;">
			</div>
		</div>
		<div class="layui-form-item layui-form-text">
			<label class="layui-form-label">备注</label>
			<div class="layui-input-inline" style="width: 78%;">
				<textarea placeholder="请输入内容" class="layui-textarea" name="remarks"></textarea>
			</div>
		</div>
		<div class="layui-tab" style="width: 90%;">
			<ul class="layui-tab-title">
				<li class="layui-this">系统管理</li>
				<li>工作人员</li>
				<li>租户/业主</li>
			</ul>
			<div class="layui-tab-content">
				<div class="layui-tab-item layui-show" >
					<div style="height: 25px;font-weight: bold;">
						<input type="checkbox" value="0" lay-skin="primary" title="全选" lay-filter="check0">
					</div>
					<table class="menu_table sysPower" 
					style="height: 330px;width:100%;border: 1px solid #dad8d8;overflow: auto;display: block;padding: 10px;">
					
					</table>
				</div>
				<div class="layui-tab-item">
					<div style="height: 25px;font-weight: bold;">
						<input type="checkbox" value="0" lay-skin="primary" title="全选" lay-filter="check1">
					</div>
					<table class="menu_table gzPower" 
					style="height: 330px;width:100%;border: 1px solid #dad8d8;overflow: auto; display: block;padding: 10px;">
					
					</table>
				</div>
				<div class="layui-tab-item">
					<div style="height: 25px;font-weight: bold;">
						<input type="checkbox" value="0" lay-skin="primary" title="全选" lay-filter="check2">
					</div>
					<table class="menu_table zhPower" 
					style="height: 330px;width:100%;border: 1px solid #dad8d8;overflow: auto; display: block;padding: 10px;">
					
					</table>
				</div>
			</div>
		</div>
		<br>
		<div class="layui-form-item" style="text-align: center;">
			<button class="layui-btn" lay-submit="" lay-filter="submitOrgForm">立即提交</button>
		</div>
	</form>
	<form class="layui-form" action="" id="addProject_form" lay-filter="addProject_form" style="display: none;padding:10px;">
		<br>
		<div style="width: 40%;float:left;">
			<div class="layui-form-item">
				<label class="layui-form-label">项目名称</label>
				<div class="layui-input-block">
					<input type="text" name="oid" class="layui-input" style="display: none;">
					<input type="text" name="fid" class="layui-input" style="display: none;">
					<input type="text" name="lng" class="layui-input" style="display: none;" id="lng">
					<input type="text" name="lat" class="layui-input" style="display: none;" id="lat">
					<input type="text" name="oname" class="layui-input" lay-verify="required" lay-reqtext="名称为必填项">
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">使用状态</label>
				<div class="layui-input-block">
					<select name="state" lay-verify="required">
						<option value="">请选择</option>
						<option value="1">使用</option>
						<option value="0">禁用</option>
					</select>
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">接入密钥</label>
				<div class="layui-input-block">
					<input type="text" name="pass" class="layui-input">
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">接入密钥</label>
				<div class="layui-input-block">
					<input type="text" name="pass" class="layui-input">
				</div>
			</div>
			<div class="layui-form-item" style="text-align: center;width: 100%;display: none" id="codeAndPass">
				<a class="layui-btn layui-btn-primary layui-btn-sm" id="setCodeAndPass">接入秘钥生成</a>
			</div>
			<div class="layui-form-item layui-form-text">
				<label class="layui-form-label">备注</label>
				<div class="layui-input-block">
					<textarea placeholder="请输入内容" class="layui-textarea" name="remarks"></textarea>
				</div>
			</div>
			<div class="layui-tab" style="width: 98%;">
				<ul class="layui-tab-title">
					<li class="layui-this">系统管理</li>
					<li>工作人员</li>
					<li>租户/业主</li>
				</ul>
				<div class="layui-tab-content">
					<div class="layui-tab-item layui-show" >
						<div style="height: 25px;font-weight: bold;">
							<input type="checkbox" value="0" lay-skin="primary" title="全选" lay-filter="projectcheck0">
						</div>
						<table class="menu_table sysPower" 
						style="height: 330px;width:100%;border: 1px solid #dad8d8;overflow: auto;display: block;padding: 10px;">
						
						</table>
					</div>
					<div class="layui-tab-item">
						<div style="height: 25px;font-weight: bold;">
							<input type="checkbox" value="0" lay-skin="primary" title="全选" lay-filter="projectcheck1">
						</div>
						<table class="menu_table gzPower" 
						style="height: 330px;width:100%;border: 1px solid #dad8d8;overflow: auto; display: block;padding: 10px;">
						
						</table>
					</div>
					<div class="layui-tab-item">
						<div style="height: 25px;font-weight: bold;">
							<input type="checkbox" value="0" lay-skin="primary" title="全选" lay-filter="projectcheck2">
						</div>
						<table class="menu_table zhPower" 
						style="height: 330px;width:100%;border: 1px solid #dad8d8;overflow: auto; display: block;padding: 10px;">
						
						</table>
					</div>
				</div>
			</div>
			<br>
			<div class="layui-form-item" style="text-align: center;">
				<button class="layui-btn" lay-submit="" lay-filter="submitProjectForm">立即提交</button>
			</div>
		</div>
		<div class="layui-col-md7" style="float: right;">
			<div style="float: right;position: relative;top: -2px;z-index: 99999;right: 100px;">
				<input type="text" id="suggestId" placeholder="详细地址搜索" style="width: 300px;" class="layui-input">
				<div id="searchResultPanel" style="border:1px solid #C0C0C0;width:150px;height:auto;display: none"></div>
			</div>
			<div id="tips_dt" style="width: 100%;height:100%;text-align: center;color:gray;margin-top:30%">
				<i class="layui-icon layui-anim layui-anim-rotate layui-anim-loop" style="font-size:18px">&#xe63e;</i>
			请稍等，地图正在加载中...</div>
			<div class="refresh_dt" title="刷新地图"><i class="layui-icon" style="color:gray;font-size: 25px;">&#xe666;</i></div>
			<div id="l-map" style="width: 100%;height: 800px;display: none;top: -40px;"></div>
		</div>
	</form>
</body>
</html>
